package com.he.ymw.service.impl;

import com.github.pagehelper.PageHelper;
import com.he.ymw.pojo.User;
import com.he.ymw.service.UserService;
import com.he.ymw.dao.UserDao;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

@Service
public class UserServiceImpl implements UserService {

//    @Autowired
    @Resource
    UserDao userDao;

    @Override
    public String findUserName(String loginName) {
        return userDao.findUserName(loginName);
    }

    @Override
    public int addUser(User user) {
        return userDao.addUser(user);
    }

    @Override
    public String findMobile(String mobile) {
        return userDao.findMobile(mobile);
    }

    @Override
    public User login(String loginName, String password) {
        return userDao.login(loginName,password);
    }
}
